﻿Partial Public Class _DefaultCopy
    Inherits System.Web.UI.Page

    'Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
    '    If Not Me.IsPostBack Then
    '        encheNoticiaEmDestaque()
    '        encheBannerGrande()
    '        encheBannerMedio()
    '        encheAlbums()
    '    End If
    'End Sub

    'Protected Sub encheNoticiaEmDestaque()
    '    Dim c As New SiteDLL.Noticia
    '    Try
    '        c.addWhere("Imagem", ClasseBase.Classes.PersistClass.TipoFiltro.Diferente, "")
    '        Dim dt As New DataTable
    '        dt = c.getTodosRegistros

    '        Me.hplNoticiaTitulo.Text = dt.Rows(dt.Rows.Count - 1).Item(1).ToString
    '        Me.hplNoticiaManchete.Text = "- " & dt.Rows(dt.Rows.Count - 1).Item(2).ToString
    '        Me.imgNoticiaDestaque.ImageUrl = dt.Rows(dt.Rows.Count - 1).Item(5).ToString

    '        Me.hplNoticiaTitulo.NavigateUrl = "VisualizaNoticia.aspx?IDnoticia=" & dt.Rows(dt.Rows.Count - 1).Item(0).ToString
    '        Me.hplNoticiaManchete.NavigateUrl = "VisualizaNoticia.aspx?IDnoticia=" & dt.Rows(dt.Rows.Count - 1).Item(0).ToString
    '    Catch ex As Exception
    '        Throw ex
    '    Finally
    '        c.Dispose()
    '        c = Nothing
    '    End Try
    'End Sub

    'Protected Sub encheBannerGrande()
    '    Dim c As New SiteDLL.Banner
    '    Try
    '        c.addWhere("Fixo", ClasseBase.Classes.PersistClass.TipoFiltro.Igual, "Sim")
    '        c.addWhere(ClasseBase.Classes.PersistClass.OperadorLogico.AND, "Tamanho", ClasseBase.Classes.PersistClass.TipoFiltro.Igual, "G")
    '        dtlBannerGrande.DataSource = c.getTodosRegistros
    '        dtlBannerGrande.DataBind()
    '    Catch ex As Exception
    '        Throw ex
    '    Finally
    '        c.Dispose()
    '        c = Nothing
    '    End Try
    'End Sub

    'Protected Sub encheBannerMedio()
    '    Dim c As New SiteDLL.Banner
    '    Try
    '        c.addWhere("Fixo", ClasseBase.Classes.PersistClass.TipoFiltro.Igual, "Sim")
    '        c.addWhere(ClasseBase.Classes.PersistClass.OperadorLogico.AND, "Tamanho", ClasseBase.Classes.PersistClass.TipoFiltro.Igual, "M")
    '        dtlBannerMedio.DataSource = c.getTodosRegistros
    '        dtlBannerMedio.DataBind()
    '    Catch ex As Exception
    '        Throw ex
    '    Finally
    '        c.Dispose()
    '        c = Nothing
    '    End Try
    'End Sub

    'Private Sub encheAlbums()
    '    Dim c As New SiteDLL.Album
    '    Try
    '        dtListAlbuns.DataSource = c.executarQuerySQL(" SELECT TOP 6 " & _
    '                                                     "   Album.IDAlbum, " & _
    '                                                     "   (Select TOP 1 Fotos.Link FROM Fotos WHERE Fotos.IDAlbum = Album.IDAlbum) as Link, " & _
    '                                                     " Album.Nome " & _
    '                                                     " FROM Album ")
    '        dtListAlbuns.DataBind()
    '    Catch ex As Exception
    '        Throw ex
    '    Finally
    '        c.Dispose()
    '        c = Nothing
    '    End Try
    'End Sub
End Class